function OrderDetailView() {
	this.parent();
}

OrderDetailView.inherits(BaseView, {
	init : function() {
		this.createOrderDetailView(this.ctrl.model.orderList);
	},

	createOrderDetailView : function(data) {
		$id("txtOrderId").value = data.orderId;
		$id("txtUserId").value = data.userId;
		$id("txtReceiverName").value = data.receiverName;
		$id("txtReceiverAddress").value = data.receiveAddress;
		$id("txtReceiverPhone").value = data.receivePhoneNumber;
		$id("txtOrderDate").value = data.orderDate;
		
		// var ship = data.shippingMethod;
		// if(ship=="1"){
// 			
		// } else (ship=="2"){
// 			
		// }
		$id("txtShippingMethod").value = data.shippingMethod;
		$id("txtPaymentMethod").value = data.paymentMethod;
		$id("txtTotalPrice").value = data.totalPrice;

		var ddlStatus = document.getElementById("txtOrderStatus");
		var opts = ddlStatus.options.length;
		for (var i = 0; i < opts; i++) {
			if (ddlStatus.options[i].value == data.status) {
				ddlStatus.selectedIndex = i;
				break;
			}
		}
		$id("btnUpdateOrder").setAttribute("onclick", "updateOrder()");
	}
});
